Get vault upgrade payload (Base -> Ethereum)
curl --request POST \
--url https://api.byzantine.fi/v1/query/get-vault-upgrade-payload-passkey \
--header 'Content-Type: application/json' \
--header 'X-Pubkey: <x-pubkey>' \
--header 'X-Pubkey, X-Timestamp, X-Signature: <api-key>' \
--header 'X-Signature: <x-signature>' \
--header 'X-Timestamp: <x-timestamp>' \
--data '
{
"accountId": "550e8400-e29b-41d4-a716-446655440000",
"sourceVaultAddr": "0x061b3aff8e21a9d194ce43cEfc20A0eFf122Ec69"
}
'import requests
url = "https://api.byzantine.fi/v1/query/get-vault-upgrade-payload-passkey"
payload = {
"accountId": "550e8400-e29b-41d4-a716-446655440000",
"sourceVaultAddr": "0x061b3aff8e21a9d194ce43cEfc20A0eFf122Ec69"
}
headers = {
"X-Pubkey": "<x-pubkey>",
"X-Timestamp": "<x-timestamp>",
"X-Signature": "<x-signature>",
"X-Pubkey, X-Timestamp, X-Signature": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Pubkey': '<x-pubkey>',
'X-Timestamp': '<x-timestamp>',
'X-Signature': '<x-signature>',
'X-Pubkey, X-Timestamp, X-Signature': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
accountId: '550e8400-e29b-41d4-a716-446655440000',
sourceVaultAddr: '0x061b3aff8e21a9d194ce43cEfc20A0eFf122Ec69'
})
};
fetch('https://api.byzantine.fi/v1/query/get-vault-upgrade-payload-passkey', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"bodyToSign": {
"type": "ACTIVITY_TYPE_SIGN_RAW_PAYLOADS",
"timestampMs": "<string>",
"organizationId": "<string>",
"parameters": {
"signWith": "<string>",
"payloads": [
"<string>"
],
"encoding": "PAYLOAD_ENCODING_HEXADECIMAL",
"hashFunction": "HASH_FUNCTION_NO_OP"
}
},
"transactionId": "550e8400-e29b-41d4-a716-446655440000",
"sourceAmount": "123.456789",
"destinationAmount": "123.456789",
"destinationVaultAddr": "0x2F99e35Ea811F3cC230B26dfF817604B5D4B6e38"
}Passkey flow
Get vault upgrade payload (Base -> Ethereum)
Returns two raw payloads to sign with one passkey prompt: a withdraw from the Base vault and a deposit on the destination Ethereum vault. The destination vault address is derived from a static mapping on the source vault address.
POST
/
v1
/
query
/
get-vault-upgrade-payload-passkey
Get vault upgrade payload (Base -> Ethereum)
curl --request POST \
--url https://api.byzantine.fi/v1/query/get-vault-upgrade-payload-passkey \
--header 'Content-Type: application/json' \
--header 'X-Pubkey: <x-pubkey>' \
--header 'X-Pubkey, X-Timestamp, X-Signature: <api-key>' \
--header 'X-Signature: <x-signature>' \
--header 'X-Timestamp: <x-timestamp>' \
--data '
{
"accountId": "550e8400-e29b-41d4-a716-446655440000",
"sourceVaultAddr": "0x061b3aff8e21a9d194ce43cEfc20A0eFf122Ec69"
}
'import requests
url = "https://api.byzantine.fi/v1/query/get-vault-upgrade-payload-passkey"
payload = {
"accountId": "550e8400-e29b-41d4-a716-446655440000",
"sourceVaultAddr": "0x061b3aff8e21a9d194ce43cEfc20A0eFf122Ec69"
}
headers = {
"X-Pubkey": "<x-pubkey>",
"X-Timestamp": "<x-timestamp>",
"X-Signature": "<x-signature>",
"X-Pubkey, X-Timestamp, X-Signature": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Pubkey': '<x-pubkey>',
'X-Timestamp': '<x-timestamp>',
'X-Signature': '<x-signature>',
'X-Pubkey, X-Timestamp, X-Signature': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
accountId: '550e8400-e29b-41d4-a716-446655440000',
sourceVaultAddr: '0x061b3aff8e21a9d194ce43cEfc20A0eFf122Ec69'
})
};
fetch('https://api.byzantine.fi/v1/query/get-vault-upgrade-payload-passkey', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"bodyToSign": {
"type": "ACTIVITY_TYPE_SIGN_RAW_PAYLOADS",
"timestampMs": "<string>",
"organizationId": "<string>",
"parameters": {
"signWith": "<string>",
"payloads": [
"<string>"
],
"encoding": "PAYLOAD_ENCODING_HEXADECIMAL",
"hashFunction": "HASH_FUNCTION_NO_OP"
}
},
"transactionId": "550e8400-e29b-41d4-a716-446655440000",
"sourceAmount": "123.456789",
"destinationAmount": "123.456789",
"destinationVaultAddr": "0x2F99e35Ea811F3cC230B26dfF817604B5D4B6e38"
}Headers
Body
application/json
Request body containing the account ID and source vault address (on Base).
Response
Payloads to sign created successfully
Response containing the two raw payloads to sign (withdraw from Base and deposit on Ethereum) in one passkey prompt.

